package mq

import (
	. "mq-apiserver/handler"
	"mq-apiserver/model"
	"mq-apiserver/pkg/errno"
	"strconv"

	"github.com/gin-gonic/gin"
)

func GetMQInfo(c *gin.Context) {
	userId, _ := strconv.Atoi(c.Param("id"))
	userInfo, err := model.GetMQUserInfo(uint64(userId))
	if err != nil {
		SendResponse(c, errno.ErrUserNotFound, nil)
		return
	}
	SendResponse(c, nil, userInfo)
}
